﻿#pragma once
#include "Page.h"
#include "Surole.h"
#include "simpleStruct.h"
#include "loadPage.h"
#include "mapPage.h"
#include "fightPage.h"
#include "change.h"
#include "BagPage.h"
#include "StorePage.h"
#include "Save.h"
class roomPage :public Page {
public:
	roomPage();
	roomPage(ROOM_NUMBER room,string name, string roleName, int roleId, vector<string> say ) ;
	roomPage(ROOM_NUMBER room, string name, double hp, double atk, string roleName, vector<string> say, int roleId);
	void updatePage(Hero& hero);
	bool isquitPage(Hero& hero);
	void drawPage(Hero& hero);
	int get_roomNumber() const { return room; };
	string get_name() const { return name; }
	Surole& get_role()  { return role; };
	void set_roomNumber(int new_id) { id = new_id;room = ROOM_NUMBER(id); };
	void set_name(string new_name) {
		name = new_name;
	};
	void changeRoom(ROOM_NUMBER position);
private:
	void loadPage();
	int get_position() const;
	int id;
	string name;
	ROOM_NUMBER room;
	Surole role;
};